package com.cmc.cloud.cmclink.doc.convert;

import com.cmc.cloud.cmclink.doc.api.document.rep.PortDescInfoRespDTO;
import com.cmc.cloud.cmclink.doc.entity.PortDescDO;
import com.cmc.cloud.cmclink.doc.vo.portdesc.PortDescCreateReqVO;
import com.cmc.cloud.cmclink.doc.vo.portdesc.PortDescInfoRespVO;
import com.cmc.cloud.cmclink.doc.vo.portdesc.PortDescRespVO;
import com.cmc.cloud.cmclink.doc.vo.portdesc.PortDescUpdateReqVO;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * 港口描述 Convert
 *
 * @author 集运管理员
 */
@Mapper
public interface PortDescConvert {

    PortDescConvert INSTANCE = Mappers.getMapper(PortDescConvert.class);

    /**
     * 属性转换 convert
     *
     * @param bean
     * @return
     */
    PortDescDO convert(PortDescCreateReqVO bean);

    /**
     * 属性转换 convert
     *
     * @param bean
     * @return
     */

    PortDescDO convert(PortDescUpdateReqVO bean);

    /**
     * 属性转换 convert
     *
     * @param bean
     * @return
     */
    PortDescRespVO convert(PortDescDO bean);

    /**
     * 属性转换 convert
     *
     * @param list
     * @return
     */

    List<PortDescRespVO> convertList(List<PortDescDO> list);

    /**
     * 属性转换
     *
     * @param portDescDoList
     * @return
     */
    List<PortDescInfoRespDTO> convertPortDescRespDto(List<PortDescInfoRespVO> portDescDoList);

}
